import { Component, NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { HomeComponent } from './home/home.component';
import { DTsComponent } from './dts/dts.component';
const routes: Routes = [  {// 这是首页路由 默认跳转到contacts
  path: '',
  redirectTo: '/home',
  pathMatch: 'full' // 必须是完全匹配，才能跳转
},
  {
    path:"home",
    component:HomeComponent
  },
  {
    path:"dts",
    component:DTsComponent
  }
];

@NgModule({
  imports: [RouterModule.forRoot(routes)],
  exports: [RouterModule]
})
export class AppRoutingModule { }
